/*************************************************************************************
 * Description  : 
 * Version      : 1.0
 * Author       : simon.yuan
 * Date         : 2021-08-16 22:12:10
 * LastEditors  : simon.yuan
 * LastEditTime : 2021-08-16 22:30:35
 * FilePath     : \\v10\\app\\main.c
 *************************************************************************************/
#include "bsp_gpio.h"
#include "bsp_uart.h"
#include "sys_delay.h"
#include "bsp_timer.h"
#include "bsp_exti.h"
#include "bsp_adc.h"

void main(void)
{
    sys_disableGlobalInterrupt();
    bsp_InitGPIO();
    bsp_InitUart();
    bsp_InitTimer0();
    bsp_extiInit();
    sys_enableGlobalInterrupt();

    while (1) {
        bsp_UartSendString("========================================\r\n");
        bsp_ADCResultShow(ADC_CH2);
        delay_ms(50);
        bsp_ADCResultShow(ADC_CH3);
        delay_ms(50);
        bsp_ADCResultShow(ADC_CH4);
        delay_ms(50);
        bsp_ADCResultShow(ADC_CH5);
        delay_ms(50);
        bsp_ADCResultShow(ADC_CH6);
        delay_ms(50);
        bsp_ADCResultShow(ADC_CH7);
        delay_ms(50);
        bsp_UartSendString("========================================\r\n");

        delay_ms(1000);
    }
}
